<HTML>
<HEAD>
	<TITLE ID='L_ErrDlg_DialogTitle'>An Error Occurred!</TITLE>
	<LINK REL='stylesheet' TYPE='text/css' HREF='/widgets/bizdesk.css' ID='mainstylesheet'>
	<STYLE>
		HTML
		{
			Width: 400px;
			Height: 340px;
		}
	</STYLE>
	<SCRIPT LANGUAGE='VBScript'>
		SUB initDialog()
		  ' Get the dialog arguments, and populate the dialog.
		  DIM dictArgs
		  SET dictArgs = window.dialogArguments

		  divErrorMsg.innerHTML = dictArgs.Item("error")
		  divDetails.innerHTML = dictArgs.Item("details")

		  CALL resizeDialog()
		END SUB

		SUB resizeDialog()
			if window.dialogHeight = "120px" then
				window.dialogHeight = "340px"
			else
				window.dialogHeight = "120px"
			end if
		END SUB

		SUB toggleDetails()
		  IF divDetails.style.display = "none" THEN
		    divDetails.style.display = ""
		  ELSE
		    divDetails.style.display = "none"
		  END IF

		  CALL resizeDialog()
		END SUB


		SUB onClose()
		  CALL window.close()
		END SUB
	</SCRIPT>
</HEAD>
<BODY onload='initDialog' STYLE="margin:0px;padding:0px;overflow:hidden">

  <DIV STYLE='margin:16px'>
    <DIV ID='divErrorMsg' STYLE='margin:16px'>
    </DIV>

    <DIV ALIGN='right'>
      <BUTTON ID='L_Close_Button' onclick='onClose()'>Close</BUTTON>
      <BUTTON ID='L_Details_Button' onclick='toggleDetails()'>Details</BUTTON>
    </DIV>

    <DIV ID='divDetails' STYLE='width:340px;height:200px;margin:16px;padding:4px;border:2px inset;display:none;overflow: auto'>
    </DIV>
  </DIV>

</BODY>
</HTML>
